package com.com.typhoon.controller;

import com.com.typhoon.dao.UserDao;
import com.com.typhoon.entity.User;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author shuya | dongfeng.zdf@alibaba-inc.com
 * @description
 * @date 2019/1/3 下午4:45
 * @description
 * @modified by
 * @since V2.0.0
 */
@RestController
public class IndexController {

    @Autowired
    private UserDao userDao;

    @GetMapping("/user")
    public List<User> queryUser() {
        return userDao.listAll();
    }

}
